package com.pureut.scheduling.mapper;

import com.pureut.scheduling.domain.SchedulingHours;
import com.pureut.scheduling.domain.dto.SchedulingHoursDto;
import com.pureut.scheduling.domain.vo.MaterialMqVo;
import com.pureut.scheduling.domain.vo.SchedulingHoursVo;

import java.util.List;

/**
 * @Description
 * @Param
 * @Date
 * @Author hl
 **/
public interface SchedulingHoursMapper {

    /**
     * 查询标准工时
     */
    List<SchedulingHoursDto> selectHoursList(SchedulingHoursVo schedulingHoursVo);

    /**
     * 新增标准工时
     */
    int insertSchedulingHours(SchedulingHours schedulingHours);

    /**
     * 修改标准工时
     */
    int updateSchedulingHoursEdit(SchedulingHours schedulingHours);

    /**
     * 删除标准工时
     */
    int deleteHoursById(String[] hoursIdS);

    /**
     * 根据线别id查询是否存在
     */
    int selectHoursLineById(long hoursLineId);

    /**
     * 根据物料编码和线别id 查询换产时间
     */
    int selectHoursBirthTime(String materialCode, long lineId);

    /**
     * 根据线别id 和物料编码 查询对应工时
     */
    SchedulingHoursDto selectHoursOnById(long lineId, String materialCode);

    /**
     * 物料同步
     */
    void updateHoursMaterial(MaterialMqVo mq);

    /**
     * 查询该物料id是否存在
     */
    int countSchedulingHours(String hoursMaterialCode);
}
